using System.Collections.Generic;
using System.Collections.ObjectModel;
using Finaltec.Hart.Analyzer.ViewModel.DataTemplate;

namespace Finaltec.Hart.Analyzer.ViewModel.DataModels
{
    public class DataTransferModel
    {
        private static DataTransferModel _instance;

        /// <summary>
        /// Gets or sets the output.
        /// </summary>
        /// <value>The output.</value>
        public ObservableCollection<CommandData> Output { get; set; }
        /// <summary>
        /// Gets or sets the hart device producer.
        /// </summary>
        /// <value>The hart device producer.</value>
        public Dictionary<string, string> HartDeviceProducer { get; set; }

        /// <summary>
        /// Initializes a new instance of the <see cref="DataTransferModel"/> class.
        /// </summary>
        private DataTransferModel()
        {
            Output = new ObservableCollection<CommandData>();

            #region HartDeviceProducer

            HartDeviceProducer = new Dictionary<string, string>
                                     {
                                                    {"01","Acromag"},
                                                    {"02","Allen Bradley"},
                                                    {"03","Ametek"},
                                                    {"04","Analog Devices"},
                                                    {"05","ABB"},
                                                    {"06","Beckman"},
                                                    {"07","Bell Microsensor"},
                                                    {"08","Bourns"},
                                                    {"09","Bristol Babcock"},
                                                    {"0A","Brooks  Instrument"},           
                                                    {"0B","Chessell"},                     
                                                    {"0C","Combustion Engineering"},       
                                                    {"0D","Daniel Industries"},            
                                                    {"0E","Delta"},                        
                                                    {"0F","Dieterich Standard"},           
                                                    {"10","Dohrmann"},                     
                                                    {"11","Endress & Hauser"},             
                                                    {"12","ABB"},                          
                                                    {"13","Fisher Controls"},              
                                                    {"14","Foxboro"},                      
                                                    {"15","Fuji"},                         
                                                    {"16","ABB"},                          
                                                    {"17","Honeywell"},                    
                                                    {"18","ITT  Barton"},                  
                                                    {"19","Thermo MeasureTech"},           
                                                    {"1A","ABB"},                          
                                                    {"1B","Leeds & Northrup"},             
                                                    {"1C","Leslie"},                       
                                                    {"1D","M-System Co."},                 
                                                    {"1E","Measurex"},                     
                                                    {"1F","Micro Motion"},                 
                                                    {"20","Moore  Industries"},            
                                                    {"21","PRIME Measurement Products"},   
                                                    {"22","Ohkura Electric"},              
                                                    {"23","Paine"},                        
                                                    {"24","Rochester  Instrument Systems"},
                                                    {"25","Ronan"},                    
                                                    {"26","Rosemount"},
                                                    {"27","Peek Measurement"},
                                                    {"28","Actaris Neptune"},
                                                    {"29","Sensall"},
                                                    {"2A","Siemens"},
                                                    {"2B","Weed"},
                                                    {"2C","Toshiba"},
                                                    {"2D","Transmation"},
                                                    {"2E","Rosemount Analytic"},
                                                    {"2F","Metso  Automation"},
                                                    {"30","Flowserve"},
                                                    {"31","Varec"},
                                                    {"32","Viatran"},
                                                    {"33","Delta/Weed"},
                                                    {"34","Westinghouse"},
                                                    {"35","Xomox"},
                                                    {"36","Yamatake"},
                                                    {"37","Yokogawa"},
                                                    {"38","Nuovo  Pignone"},
                                                    {"39","Promac"},
                                                    {"3A","Exac  Corporation"},
                                                    {"3B","Mobrey"},
                                                    {"3C","Arcom Control System"},
                                                    {"3D","Princo"},
                                                    {"3E","Smar"},
                                                    {"3F","Foxboro  Eckardt"},
                                                    {"40","Measurement  Technology"},
                                                    {"41","Applied System Technologies"},
                                                    {"42","Samson"},
                                                    {"43","Sparling  Instruments"},
                                                    {"44","Fireye"},
                                                    {"45","Krohne"},
                                                    {"46","Betz"},
                                                    {"47","Druck"},
                                                    {"48","SOR"},
                                                    {"49","Elcon  Instruments"},
                                                    {"4A","EMCO"},
                                                    {"4B","Termiflex  Corporation"},
                                                    {"4C","VAF  Instruments"},
                                                    {"4D","Westlock  Controls"},
                                                    {"4E","Drexelbrook"},
                                                    {"4F","Saab Tank Control"},
                                                    {"50","K-TEK"},
                                                    {"51","SENSIDYNE, INC"},
                                                    {"52","Draeger"},
                                                    {"53","Raytek"},
                                                    {"54","Siemens Milltronics PI"},
                                                    {"55","BTG"},
                                                    {"56","Magnetrol"},
                                                    {"57","Metso  Automation"},
                                                    {"58","Siemens Milltronics PI"},
                                                    {"59","HELIOS"},
                                                    {"5A","Anderson  Instrument Company"},
                                                    {"5B","INOR"},
                                                    {"5C","ROBERTSHAW"},
                                                    {"5D","PEPPERL+FUCHS"},
                                                    {"5E","ACCUTECH"},
                                                    {"5F","Flow Measurement"},
                                                    {"60","Bourdon-Haenni"},
                                                    {"61","Knick"},
                                                    {"62","VEGA"},
                                                    {"63","MTS Systems Corp."},
                                                    {"64","Oval"},
                                                    {"65","Masoneilan-Dresser"},
                                                    {"66","BESTA"},
                                                    {"67","Ohmart"},
                                                    {"68","Harold Beck and Sons"},
                                                    {"69","rittmeyer  instrumentation"},
                                                    {"6A","Rossel Messtechnik"},
                                                    {"6B","WIKA"},
                                                    {"6C","Bopp & Reuther Messtechnik"},
                                                    {"6D","PR Electronics"},
                                                    {"6E","Jordan Controls"},
                                                    {"6F","Valcom s.r.l."},
                                                    {"70","US ELECTRIC MOTORS"},
                                                    {"71","Apparatebau Hundsbach"},
                                                    {"72","Dynisco"},
                                                    {"73","Spriano"},
                                                    {"74","Direct Measurement"},
                                                    {"75","Klay  Instruments"},
                                                    {"76","CiDRA CORP."},
                                                    {"77","MMG AM DTR"},
                                                    {"78","Buerkert Fluid Control Systems"},
                                                    {"79","AALIANT Process Mgt"},
                                                    {"7A","PONDUS INSTRUMENTS"},
                                                    {"7B","ZAP S.A. Ostrow Wielkopolski"},
                                                    {"7C","GLI"},
                                                    {"7D","Fisher-Rosemount  Performance  Technologies"},
                                                    {"7E","Paper Machine  Components"},
                                                    {"7F","LABOM"},
                                                    {"80","Danfoss"},
                                                    {"81","Turbo"},
                                                    {"82","TOKYO KEISO"},
                                                    {"83","SMC"},
                                                    {"84","Status  Instruments"},
                                                    {"85","Huakong"},
                                                    {"86","Duon System"},
                                                    {"87","Vortek  Instruments, LLC"},
                                                    {"88","AG Crosby"},
                                                    {"89","Action  Instruments"},
                                                    {"8A","Keystone  Controls"},
                                                    {"8B","Thermo  Electric Co."},
                                                    {"8C","ISE Magtek"},
                                                    {"8D","Rueger"},
                                                    {"8E","Mettler  Toledo"},
                                                    {"8F","Det-Tronics"},
                                                    {"90","Thermo MeasureTech"},
                                                    {"91","DeZURIK"},
                                                    {"92","Phase Dynamics"},
                                                    {"93","WELLTECH SHANGHAI"},
                                                    {"94","ENRAF"},
                                                    {"95","4tech ASA"},
                                                    {"96","Brandt  Instruments"},
                                                    {"97","Nivelco"},
                                                    {"98","Camille Bauer"},
                                                    {"99","Metran"},
                                                    {"9A","Milton Roy Co."},
                                                    {"9B","PMV"},
                                                    {"9C","Turck"},
                                                    {"9D","Panametrics"},
                                                    {"9E","R. Stahl"},
                                                    {"9F","Analytical  Technology  Inc."},
                                                    {"A0","FINT"},
                                                    {"A1","BERTHOLD"},
                                                    {"A2","InterCorr"},
                                                    {"A3","China BRICONTE Co Ltd"},
                                                    {"A4","Electron Machine"},
                                                    {"A5","Sierra  Instruments"},
                                                    {"A6","Fluid Components  Intl"},
                                                    {"A7","Solid AT"},
                                                    {"A8","Meriam  Instrument"},
                                                    {"A9","Invensys"},
                                                    {"AA","S-Products"},
                                                    {"AB","Tyco Valves & Controls"},
                                                    {"AC","Micro Matic  Instrument A/S"},
                                                    {"AD","J-Tec Associates"},
                                                    {"AE","TRACERCO"},
                                                    {"AF","AGAR"},
                                                    {"B0","Phoenix  Contact"},
                                                    {"B1","Andean  Instruments"},
                                                    {"B2","Amer. Level  Instr."},
                                                    {"B3","Hawk"},
                                                    {"B4","YTC"},
                                                    {"B5","Pyromation  Inc."},
                                                    {"B6","Satron  Instruments"},
                                                    {"B7","BIFFI"},
                                                    {"B8","SAIC"},
                                                    {"B9","BD Sensors"},
                                                    {"BA","Andean  Instruments"},
                                                    {"BB","Kemotron"},
                                                    {"BC","APLISENS"},
                                                    {"BD","Badger Meter"},
                                                    {"BE","HIMA"},
                                                    {"BF","GP:50"},
                                                    {"C0","Kongsberg Maritime"},
                                                    {"C1","ASA S.p.A."},
                                                    {"C2","Hengesbach"},
                                                    {"C3","Lanlian  Instruments"},
                                                    {"C4","Spectrum Controls"},
                                                    {"C5","Kajaani Process Measurements"},
                                                    {"C6","FAFNIR"},
                                                    {"C7","SICK-MAIHAK"},
                                                    {"C8","JSP Nova Paka"},
                                                    {"C9","MESACON"},
                                                    {"CA","Spirax Sarco Italy"},
                                                    {"CB","L&J TECHNOLOGIES"},
                                                    {"CC","Tecfluid S.A."},
                                                    {"CD","Sailsors  Instruments"},
                                                    {"CE","Roost"},
                                                    {"CF","KOSO"},
                                                    {"D0","MJK"},
                                                    {"D1","GE Energy"},
                                                    {"D2","BW Technologies"},
                                                    {"D3","HEINRICHS"},
                                                    {"D4","SIC"},
                                                    {"D5","HACH LANGE"},
                                                    {"D6","Exalon  Instruments"},
                                                    {"D7","FAURE HERMAN"},
                                                    {"D8","STI S.r.l."},
                                                    {"D9","Manometr-Kharkiv"},
                                                    {"DA","Dalian-Instruments"},
                                                    {"DB","Spectrex"},
                                                    {"DC","SIPAI  Instruments"},
                                                    {"DD","Advanced Flow"},
                                                    {"DE","Rexa. Koso America"},
                                                    {"DF","General Monitors,  Inc."},
                                                    {"E0","Manufacturer  Expansion"},
                                                    {"F9","HART Communication Foundation"}
                                     };

            #endregion
        }

        /// <summary>
        /// Gets the instance.
        /// </summary>
        /// <returns></returns>
        public static DataTransferModel GetInstance()
        {
            return _instance ?? (_instance = new DataTransferModel());
        }
    }
}